



<?php


use yii\helpers\Html;
use yii\widgets\DetailView;
use yii\helpers\Url;
use yii\bootstrap\Modal;
?>




<html>


<body id="page1" style="width:1000px;">



<div class="extra" ">
<div style="width:600px;height:600px;position:relative">



        <div class="wrapper under" style="position:absolute;width:880px;left:-50px; top:0px;">

            <figure class="left marg_right1"></figure>

            <div style="width:50%;height:100%;float:left">
                <table>

                    <tr > <?= Html::img('../assets/img/3.jpg', ['alt' => 'My logo', 'width' => '250px']) ?></tr>
                </table>

                <hr  width=300 size=2 color=#5151A2 align=center noshade>

            </div>

            <div style="width:50%;height:100%;float:left">
                <table style="border:0px;">
                    <?php  foreach($system_model as $model) {

                        ?>
                        <tr ><td style="border:0px;background:white;"><?=$model->index_name?>:  </strong></td>
                            <td style="border:0px;background:white;"><?=$model->index_descript?>:  </strong></td>

                        </tr>
                        <?php
                    }
                    ?>
                </table>
            </div>



 </div>





        <div class="wrapper under" style="position:absolute;width:860px; left:-10px; top:250px;">

            <figure class="left marg_right1"></figure>



            <div style="width:50%;height:100%;float:left">
                <table style="border:0px;">

                    <tr ><td style="border:0px;color:green;background:white;"><img src="../assets/img/11.png"></td>
                        <td style="border:0px;color:green;background:white;"><strong>溯源档案完整度 </strong><br/>
                            <img src="../assets/img/12.png">
                        </td>

                        <td style="border:0px;color:green;background:white;">
                            <img src="../assets/img/13.png">
                            <?= Html::a('查看图片',['manure/index'], ['class' => 'btn btn-success','style'=>['TEXT-DECORATION'=>'none']])?>

                        </td>

                        <td style="border:0px;color:green;background:white;">
                            <img src="../assets/img/14.png">

                            <a href="#" url='<?=Url::to("index.php?r=frontend/manure/index&id=".$id2)?>' class = 'btn btn-success' style='TEXT-DECORATION:none' pid='<?=$id2?>'>查看肥料</a>



                        <td style="border:0px;color:green;background:white;">
                            <img src="../assets/img/15.png">

                            <a href="#" url='<?=Url::to("index.php?r=frontend/pesticide/index&id=".$id2)?>' class = 'btn btn-success' style='TEXT-DECORATION:none' pid='<?=$id2?>'>查看农药</a>
                        </td>

                        <td style="border:0px;color:green;background:white;">
                            <img src="../assets/img/16.png">
                            <?= Html::a('查看监控',['batch/index'], ['class' => 'btn btn-success','style'=>['TEXT-DECORATION'=>'none']])?>
                        </td>
                        <td style="border:0px;color:green;background:white;">
                            <img src="../assets/img/17.png">
                            <?= Html::a('查看环境',['batch/index'], ['class' => 'btn btn-success','style'=>['TEXT-DECORATION'=>'none']])?>
                        </td>

                    </tr>

                </table>

            </div>



      </div>
</body>
</html>


<?php
$js = <<< JS

$(function(){

    $("a").each(function(){
       if($(this).text()=='查看农药'){
           $(this).click(function(){
                var id = $(this).attr('pid');
                var url = $(this).attr('url');
               // alert(url)
               //$('#modal'+id).modal('hide');
               $('#pesticide'+id).modal('show')
                   .find('#pesticideContent'+id)
                   .load(url);

           })

       }
    })

});



JS;
$this->registerJs($js);

?>

<?php
$js = <<< JS

$(function(){

    $("a").each(function(){
       if($(this).text()=='查看肥料'){
           $(this).click(function(){
                var id = $(this).attr('pid');
                var url = $(this).attr('url');
               // alert(url)
           //     $('#modal'+id).modal('hide');
               $('#manure'+id).modal('show')
                   .find('#manureContent'+id)
                   .load(url);

           })

       }
    })

});



JS;
$this->registerJs($js);

?>




